\documentclass[a4paper]{article}

\usepackage[utf8]{inputenc}
\usepackage[T2A]{fontenc}
\usepackage[russian]{babel}

\usepackage{verbatim}
\usepackage{graphicx}
\usepackage{indentfirst}
\usepackage[a4paper,top=2.5cm,bottom=2.5cm,left=2.5cm,right=1cm,head=17pt]{geometry}

\usepackage{tabularx}
\newcolumntype{Y}{>{\centering\arraybackslash}X}

\usepackage{amssymb}
\renewcommand{\le}{\leqslant}
\renewcommand{\ge}{\geqslant}

\usepackage{ifpdf}
\ifpdf
\DeclareGraphicsRule{*}{mps}{*}{}
\fi

\newcounter{algorithm}
\newenvironment{algorithm}[1]{\par\smallskip\noindent\refstepcounter{algorithm}%
  \textbf{Алгоритм \arabic{algorithm}. #1}\begin{enumerate}}{\end{enumerate}}

\newtheorem{define}{Определение}
\renewcommand{\thedefine}{\arabic{define}.}

\newtheorem{theorem}{Теорема}
\renewcommand{\thetheorem}{\arabic{theorem}.}

\renewcommand{\thesection}{\arabic{section}.}

\newcommand{\ticket}[1]{\noindent{\huge{}#1}}

\frenchspacing
